const Router = require('koa-router');
const { createProject, getProjectList, updateProjectById, deleteProjectById, queryProjectById } = require('../controller/project.controller');
const { idValidator } = require('../middleware');
const { projectValidatorMiddleware } = require('../middleware/project.middleware');
const router = new Router();

router.get('/:id', idValidator, queryProjectById);
router.post('/', getProjectList)
router.post('/create', projectValidatorMiddleware, createProject);
router.post('/edit', idValidator, updateProjectById);
router.post('/del', idValidator, deleteProjectById);
module.exports = router